<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">

<head>
	<title th:text="${title}"></title>
	<meta charset="utf-8">
	<meta name="uid" th:content="${uid}"/>
    <meta name="mysteriousinstructions" th:content="${mysterious}"/>
	<meta name="mecha" th:content="${mecha}"/>
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<link rel="stylesheet" href="https://cdn.staticfile.org/font-awesome/4.7.0/css/font-awesome.css">
	<link rel="stylesheet" href="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/lib/codemirror.css" />
	<link rel="stylesheet" href="https://cdn.staticfile.org/twitter-bootstrap/5.1.1/css/bootstrap.min.css" />
	<link rel="stylesheet" href="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/theme/dracula.css" />
	<link rel="stylesheet" href="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/theme/night.css" />
	<link rel="stylesheet" href="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/fold/foldgutter.css" />
	<link rel="stylesheet" href="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/display/fullscreen.css" />
	<link rel="stylesheet" href="https://pan.ray0728.cn/MyDAV/cdn/codeonline/css/codemirror.css" />
	<link rel="stylesheet" href="https://pan.ray0728.cn/MyDAV/cdn/codeonline/css/card.css" />
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/lib/codemirror.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/fold/foldcode.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/fold/foldgutter.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/fold/brace-fold.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/fold/comment-fold.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/edit/matchbrackets.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/addon/display/fullscreen.js"></script>
	<script src="https://cdn.staticfile.org/jquery/3.2.1/jquery.min.js"></script>
	<script src="https://cdn.staticfile.org/popper.js/1.15.0/umd/popper.min.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/mode/python/python.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/codemirror/mode/shell/shell.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/js/editor.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/js/cm.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/js/mecha.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/js/usercode.js"></script>
	<script src="https://pan.ray0728.cn/MyDAV/cdn/codeonline/js/modal.js"></script>
	<script src="https://cdn.staticfile.org/twitter-bootstrap/5.1.1/js/bootstrap.bundle.min.js"></script>
	<script th:inline="javascript">
		$(document).ready(function () {
			window.wss = init("wss://" + location.host + /*[[${url}]]*/'/');
		});
	</script>
</head>

<body>
	<div class="container-fluid">
		<div class="row">
			<div class="card col-sm-6 col-md-6 col-lg-6 col-xl-6">
				<div class="card-header">
					<div class="btn-group">
						<button type="button" class="btn btn-primary fa fa-paper-plane"
							onClick="exec(input,'py')"></button>
						<button type="button" class="btn btn-secondary fa fa-cloud-download" data-bs-toggle="modal"
							data-bs-target="#dialogLoad"></button>
						<button type="button" class="btn btn-success fa fa-cloud-upload" data-bs-toggle="modal"
							data-bs-target="#dialogUpload"></button>
					</div>
					<div class="btn-group" style="float:right">
						<button type="button" class="btn btn-warning fa fa-trash-o" onClick="values(input)" ,
							data-bs-toggle="modal" data-bs-target="#dialogClean"></button>
						<button type="button" class="btn btn-secondary fa fa-undo" onClick="undo(input)"></button>
						<button type="button" class="btn btn-secondary fa fa-repeat" onClick="repeat(input)"></button>
						<button type="button" class="btn btn-secondary fa fa-window-maximize"
							onClick="enterFull(input)"></button>
					</div>
				</div>
				<div class="card-body">
					<textarea class="form-control" id="input" style="margin:0;padding:0;width:100%;height:100%;">
					</textarea>
				</div>
			</div>
			<div class="card col-sm-6 col-md-6 col-lg-6 col-xl-6">
				<div class="card-header" style="display: flex;">
					<div id="alert" class="alert alert-dismissible fade marquee-root"
						style="margin:0;padding:0;width:100%;height:100%;">
						<div id="alertmsg" class="alertmsg marquee-content"></div>
					</div>
					<div class="btn-group" style="padding-left:2px;float:right">
						<button type="button" class="btn btn-warning fa fa-trash-o" onClick="values(output)" ,
							data-bs-toggle="modal" data-bs-target="#dialogClean"></button>
						<button type="button" class="btn btn-secondary fa fa-window-maximize"
							onClick="enterFull(output)"></button>
					</div>
				</div>
				<div class="card-body">
					<textarea class="form-control" id="output" style="margin:0;padding:0;width:100%;height:100%;">
					</textarea>
				</div>
			</div>
		</div>
	</div>
	<div th:replace="modal::dialog"></div>
</body>

</html>